#include "Undo.h"
#include "Undoable.h"
#include <iostream>

using namespace std;

void Undo :: process(Uint8* keys)
{
	Undoable* command = Undoable :: getLastCmd();

	if (command != NULL)
	{
		command->undo(); // Perform an undo!!!
		delete command;
	} 
	else 
	{
		cout << "Nothing to be undone!!!\n";
	}
}